home *** CD-ROM | disk | FTP | other *** search
/ Language/OS - Multiplatform Resource Library / LANGUAGE OS.iso / cpp_libs / answrbok / shape.lha / shape / shape.h < prev    next >
C/C++ Source or Header  |  1993-08-08  |  1KB  |  48 lines

  1. ifndef SHAPE_H
  2. define SHAPE_H
  3. include "screen.h"
  4.  
  5. include "gslist.h"
  6.  
  7. truct shape;
  8.  
  9. ypedef shape* sp;
  10. eclare(gslist,sp);
  11.  
  12. ypedef gslist(sp) shape_lst;
  13. ypedef gslist_iterator(sp) sl_iterator;
  14. xtern shape_lst shape_list;
  15.  
  16. truct shape
  17.  
  18.    shape() { shape_list.append(this); }
  19.  
  20.    virtual point north() { return point(0,0); }
  21.    virtual point neast() { return point(0,0); }
  22.    virtual point east()  { return point(0,0); }
  23.    virtual point seast() { return point(0,0); }
  24.    virtual point south() { return point(0,0); }
  25.    virtual point swest() { return point(0,0); }
  26.    virtual point west()  { return point(0,0); }
  27.    virtual point nwest() { return point(0,0); }
  28.    virtual point middle(){ return point(0,0); }
  29.  
  30.    virtual void draw() {};
  31.    virtual void move(int, int) {};
  32.    friend void shape_refresh();
  33.    friend void stack(shape*, shape*);
  34. ;
  35.  
  36. xtern void shape_refresh();
  37. xtern void stack(shape*, shape*);
  38.  
  39. ifdef RECTFIRST
  40.  include <rectangle.h>
  41.  include <line.h>
  42. else
  43.  include <line.h>
  44.  include <rectangle.h>
  45. endif
  46.  
  47. endif
  48.